unit Unit1;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, RzTabs, ComCtrls, Menus;

type
  TForm1 = class(TForm)
    RzPageControl1: TRzPageControl;
    TabSheet1: TRzTabSheet;
    TabSheet2: TRzTabSheet;
    RzPageControl2: TRzPageControl;
    TabSheet3: TRzTabSheet;
    TabSheet4: TRzTabSheet;
    TabSheet5: TRzTabSheet;
    MainMenu1: TMainMenu;
    N1: TMenuItem;
    PageControl1: TMenuItem;
    PageControl2: TPageControl;
    TabSheet6: TTabSheet;
    TabSheet7: TTabSheet;
    TabSheet8: TTabSheet;
    procedure TabSheet5DblClick(Sender: TObject);
    procedure TabSheet5PaintBackground(Sender: TObject; ACanvas: TCanvas;
      const ARect: TRect; var Handled: Boolean);
    procedure RzPageControl2DblClick(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

{$R *.dfm}

procedure TForm1.TabSheet5DblClick(Sender: TObject);
begin
  TabSheet5.TabVisible:=False;
  ShowMessage('True');
end;

procedure TForm1.TabSheet5PaintBackground(Sender: TObject;
  ACanvas: TCanvas; const ARect: TRect; var Handled: Boolean);
begin
  ACanvas.Brush.Color:=clRed;
end;

procedure TForm1.RzPageControl2DblClick(Sender: TObject);
begin
  self.RzPageControl2.ActivePage.TabVisible:=False;
end;

end.
